
	<template>
    		<el-select  placeholder="锁定" class="header3"  @change="open2" value="">
    <el-option
	 class="header3-next"
      v-for="item in options"
      :key="item.value"
      :label="item.label"
      :value="item.value">
    </el-option>
  </el-select>
  
  </template>
  
  <script>
  export default {
     data() {
      return {
        options: [{
          value: '选项1',
          label: '锁定桌面'
        }, {
          value: '选项2',
          label: '锁定：30分钟'
        }],
        value: ''
      }
    },
    methods: {
      open2:function(value) {
        if(value=='选项1'){
          this.$confirm('是否锁定?', '提示', {
          confirmButtonText: '是',
          cancelButtonText: '否',
          type: 'warning'
        }).then(() => {
          this.$message({
            type: 'success',
            message: '已锁定!'
          });
        }).catch(() => {
          this.$message({
            type: 'info',
            message: '已取消'
          });          
        });
        }else{
            if(value=='选项2'){
          this.$confirm('是否锁定?', '提示', {
          confirmButtonText: '是',
          cancelButtonText: '否',
          type: 'success'
        }).then(() => {
          this.$message({
            type: 'success',
            message: '已锁定!'
          });
        }).catch(() => {
          this.$message({
            type: 'info',
            message: '已取消'
          });          
        });
        }
        }
        
      }
    }
  }
  </script>
  
  <style lang="scss" scoped>
 .header3{
      width:77px;
     
	// border: 1px solid;
  height: 100%;
}
.header3-next{
        width:131px;
        margin-left: 31px;
        color: black;
        background: #8a888b;
        margin-bottom: 5px;
        border-radius: 5%;
        border-radius: 5%;
        margin-top: 16px;
       height: 30px;
       color: white;
       }
      .header3-next:hover{
        background: #fefefe;
        color: #7d7b7a;
      }


.header3 /deep/ .el-input{
  width:77px;
  font-size: 15px;
  height: 100%;
}
</style>
  
